package com.rd.student.jiaji.class1.wangyufang.day0731;

import java.util.ArrayList;
import java.util.Collections;

public class TestRandom2 {
    public static void main(String[] args) {
        ArrayList<Integer> arrayList = new ArrayList<>();
        for (int i = 0; i < 50; i++) {
          arrayList.add(i);
        }
        Collections.shuffle(arrayList);
        System.out.println(arrayList);
        for (int i = 0; i < 20; i++) {
            System.out.print(arrayList.get(i)+"、");

        }
    }
}
